package com.craney.aboutNamesapce
{
	
	public class NamespaceFirst
	{
		use namespace heather;
		
		public namespace craney = "http://www.craney.prs";
		public namespace kulu = "http://www.craney.prs";
		craney var z:int = 1;
		kulu var z2:int = 2;
		
		
		
		
		//这可能是个Bug
		//编译未报错，运行时出错。
		//名字冲突
		heather var x:String = "heather x1";
//		

//		hehe var x:String = "x2 hehe";

		private var x:String = "private x";
		
		public function NamespaceFirst()
		{
			
			trace("--------------------" + heather::x);
			trace(heather);
		}

		heather function f():void
		{
			trace("sueccessful in " + NamespaceFirst);
		}
		
		craney function g():void
		{
			trace("good in " + NamespaceFirst);
		}
		
		public function printNamespace(ns:Namespace):Namespace
		{
			trace("prefix = " + ns.prefix);
			trace("uri = " + ns.uri);
			
			return hehe;
		}
		
	}
}